<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Operation extends CI_Controller {

	public function __construct()
	{
		parent::__construct();
		$this->load->model('Operation_model','oper');
		if(empty($_SESSION['id'])){
      echo "0";
      echo "<script src='/static/js/jquery.min.js?v=2.1.4'></script>";
      echo "<script src='/static/js/layer/layer.js'></script>";
      echo "<script>layer.msg('你还没有登录，请先登录',{icon:2});setTimeout(function(){window.location.href='/login';},1500)</script>";
      exit;
    }
	}

	public function index()
	{
		$data = array(
			'log'=>$this->oper->getList(array('uid'=>$_SESSION['id']))
		);
		$this->load->view('operation', $data);
	}

}

/* End of file operation.php */
/* Location: ./application/controllers/operation.php */